from playwright.sync_api import  sync_playwright
import time,pytest

@pytest.fixture
def page():
    with sync_playwright() as p:
        browser = p.chromium.launch(headless=False)
        page = browser.new_page()
        yield page
        page.close()

def test_login_001(page):
    page.goto('https://www.jiuxian.com/')
    page.click('xpath=/html/body/div[2]/div/div[1]/div/a[1]')
    page.fill('xpath=//*[@id="userName"]','18615488780')
    page.fill('xpath=//*[@id="password"]','lr123456.')
    time.sleep(15)
    page.click('xpath=//*[@id="save"]')
    page.click('.bindSub')
    time.sleep(5)